<style>
    .tip{
        padding-top: 10px;
        color: #b2b2b2;
    }
</style>
<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Apps_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-apps_id" data-rule="required" data-source="card/apps/index" class="form-control selectpage" name="row[apps_id]" type="text" value="">
            <div class="tip">卡密所属应用</div>
        </div>
    </div>


    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Day')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-day" data-rule="required" class="form-control" name="row[day]" type="number" value="">
            <div class="tip">
                {neq name="admin.id" value="1"}
                    <div>卡密激活后有效天数，当前基础天卡生成费用：<span style="color: red">{$price}</span></div>
                    {foreach name='$discountArr' item='val' key='key'}
                        <div>生成天数 >= {$key}天，{$val * 100 ? ($val * 100) . '%' : '无'} 优惠</div>
                    {/foreach}
                {/neq}
            </div>
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('生成数量')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-number" data-rule="required" class="form-control" max="1000" name="row[number]" type="number" value="">
            <div class="tip">最大生成数量 9999</div>
        </div>
    </div>

    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
